package com.cloud.api.domain.model;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.cloud.api.validgroup.ValidateGroupInsert;
import com.cloud.api.validgroup.ValidateGroupUpdate;
import com.cloud.core.entity.base.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotEmpty;
import jakarta.validation.constraints.Size;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;
import java.io.Serializable;

/**
 * <p>
 * 
 * </p>
 *
 * @author haohaibo
 * @since 2023-12-20
 */
@Getter
@Setter
@Accessors(chain = true)
@TableName("t_vehicle_model")
@Schema(name = "VehicleModel", description = "")
public class VehicleModel extends BaseEntity implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId("id")
    @NotEmpty(message = "",groups = ValidateGroupUpdate.class)
    private String id;

    @Schema(description = "车辆类别: 新能源ev，油车oil")
    @TableField("type")
    @NotEmpty(message = "",groups = ValidateGroupInsert.class)
    private String type;

    @Schema(description = "车型名称")
    @TableField("model_name")
    @NotEmpty(message = "{validation.model.modelName}")
    @Size(max = 30,min = 2,message = "{validation.common.size}")
    private String modelName;

    @Schema(description = "父id")
    @TableField("parent_id")
    @NotEmpty(message = "",groups = ValidateGroupInsert.class)
    private String parentId;

    @Schema(description = "图片",hidden = true)
    @TableField(exist = false)
    private String pictureUrl;

}